<template>
	<view class="container">
		<uni-card title="选择快递点" style="margin-top: 0px;">
			<view v-for="(item,index) in list2" :key="index" @click="ji(item)">
				<view class="" style="display: flex;">
					<image :src="item.image" style="height: 70px;width: 70px;" mode=""></image>
					<view class="item" style="margin-left: 10px;">
						<view class="">快递名称：{{item.title}}</view>
						<view class="">地址：{{item.address}}</view>
						<view class="">联系方式：{{item.phone}}</view>
					</view>
				</view>
				<view class="line"></view>
			</view>
		</uni-card>
		<uni-card title="历史寄件" style="margin-top: 10px;">
			<view v-for="(item,index) in 6" :key="index" @click="to(item)">
				<view class="item" style="display: flex;justify-content: space-between;">
					<view class="">寄出一箱水果 </view>
					<uni-dateformat style="font-size: 12px;color: #737373;flex: 1;text-align: end;" />
				</view>
				<view class="item">快递员：张三</view>
				<view class="item">快递站：顺丰快递</view>
				<view class="line"></view>
			</view>
		</uni-card>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				list2: [{
						image: "/static/b1.jpg",
						title: "顺丰快递",
						address: "小明街道100号",
						phone: "123456"
					},
					{
						image: "/static/b2.jpg",
						title: "邮政快递",
						address: "小明街道101号",
						phone: "123456"
					},
					{
						image: "/static/b3.jpg",
						title: "京东快递",
						address: "小明街道103号",
						phone: "123456"
					},
					{
						image: "/static/b1.jpg",
						title: "顺丰快递1",
						address: "小明街道100号",
						phone: "123456"
					},
					{
						image: "/static/b1.jpg",
						title: "顺丰快递2",
						address: "小明街道100号",
						phone: "123456"
					},
				]
			};
		},
		onLoad(item) {

		},
		onReady() {

		},
		onShow() {

		},
		methods: {
			ji(item) {
				uni.navigateTo({
					url: 'add/add?data='+JSON.stringify(item),
					success: res => {},
					fail: () => {},
					complete: () => {}
				});
			},
			to(item) {
				uni.navigateTo({
					url: 'detail/detail',
					success: res => {},
					fail: () => {},
					complete: () => {}
				});
			}
		}
	};
</script>

<style lang="scss">

</style>
